import { Order } from "../order/order-model";

class OrderList extends Order{

  getOrderList(page = 1,callBack,ecallBack){
    var params = {
      url:'order/list?page='+page,
      sCallBack:function(res){ callBack && callBack(res.data) },
      eCallBack:function(err){ ecallBack && ecallBack(err.data)}
    }
    this.request(params);
  }

  deleteOrder(id,callBack,ecallBack){
    var params = {
      url:'order/delete?id='+id,
      sCallBack:function(res){ callBack && callBack(res.data) },
      eCallBack:function(err){ ecallBack && ecallBack(err.data)}
    }
    this.request(params);
  }
}
export{OrderList};